-
Notifications
You must be signed in to change notification settings - Fork 29.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
build: Updates to enable AIX support #2364
Conversation
@jbergstroem, FYI. I'm still working on getting an AIX machine that can be used in the build farm but these are the changes that allow AIX to compile/run. |
@mhdawson if possible, it'd be great if I could get access to that machine (when available) so I can review this PR. |
Unfortunately getting the machine is not that far along. Its more in the 1-2 month timeframe that I could see it becoming a reality so I don't want to block the PR on that. It is important to me to get these in so that our builds use as close as possible to the community source. I can't give you access to the internal machines we have for building but I could set up a screen share where I've done builds and I could show you the builds and we could look into files that you are interested in looking at. If that works I'd like to set it up for early next week as I'm away on vacation the week after that. |
'__LITTLE_ENDIAN=1234', | ||
'__BIG_ENDIAN=4321', | ||
'__BYTE_ORDER=__BIG_ENDIAN', | ||
'__FLOAT_WORD_ORDER=__BIG_ENDIAN'], |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What uses this? The only thing I can find in the source tree is openssl. Doesn't it make more sense to add it to openssl.gyp(i)?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks like moving it to openssl.gyp works. Done.
@ bnoordhuis first set of updates and a few questions added |
@ bnoordhuis I've updated to address all of the comments/discussion. With this patch Node will compile for AIX 32 bit although 64 bit won't due to the removal of the gyp part. Still a good first step I think as it will get it compiling on 32 bit. I also opened an issue to get the gyp part upstreamed here: https://code.google.com/p/gyp/issues/detail?id=495&q=AIX While doing this I found the IBM'r who originally added the AIX support in gyp so I'm hoping he can help get the updates accepted in a reasonable timeframe. I'm heading out on vacation for a week so if there are any additional comments to address I won't respond until then. If it looks ok and there are approvals when I get back I'll squash and land. |
matchup = { | ||
'_ARCH_PPC' : 'ppc', | ||
'_ARCH_PPC64' : 'ppc64', | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is a no-op, isn't it? The second definition of matchup
a few lines below overrides it again.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I assume you just mean the matchup part. Good point. Since I thought we needed those lines I it seemed like I'd gotten it right when I moved them from the original list (they were removed from earlier patches because alphabetizing had caused issues) . I'll validate that I can just remove them and AIX still builds ok.
FYI - pull request for gyp change - https://codereview.chromium.org/1319663007 |
@bnoordhuis confirmed that we don't need those lines and added commit to remove them. |
I think this is ready to go, just waiting on a final l.g.t.m |
@@ -310,7 +310,7 @@ def JS2C(source, target): | |||
else: | |||
ids.append((id, len(lines))) | |||
|
|||
escaped_id = id.replace('/', '$') | |||
escaped_id = id.replace('/', '_') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
what's up with this?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If I am not wrong this was discussed with @vkurchatkin before.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For posterity, it's mentioned in the commit log: sigils in identifiers are not supported on AIX.
I'm clearly not qualified to review most of it but that's because most of it is isolated to AIX specific blocks, aside from the /dev/stdin, js2c.py, ENOTEMPTY and SIGLOST changes it seems to be nicely separate. I'd like to hear more about the js2c change and the ENOTEMPTY & SIGLOST seem to make sense even if AIX wasn't the only one where those cases held. So, lgtm pending feedback on js2c and also a CI run as we need to verify that everything else still works. /cc @nodejs/build |
I'm with @rvagg here. Problem also being I can't verify by running tests on an actual AIX platform. |
Yup the js2c change was discussed here #2272 as noted in the initial description. I've run on AIX as well as pLinux and xLinux locally, and of course would run through CI job before landing. CI job started here: https://ci.nodejs.org/job/node-test-pull-request/277/. Will check results when I'm back in the office next week. |
CI run was clean except for freebsd101-32 which was failing in the prior CI runs at the time (ie for CI runs for other PRs run around that time). @rvagg do you have any other questions in respect to the js2c change ? |
@@ -542,7 +546,10 @@ def is_arm_hard_float_abi(): | |||
def host_arch_cc(): | |||
"""Host architecture check using the CC command.""" | |||
|
|||
k = cc_macros() | |||
if sys.platform.startswith('aix'): | |||
k = cc_macros('gcc') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you add a comment here explaining why it hard-codes gcc?
LGTM with a request. |
Incorporated comments from bnoordhuis and revalidated in local build, just hoping for final ok from @rvagg |
lgtm |
These are the core changes that allow AIX to compile. There are still some test failures as there are some patches needed for libuv and npm that we'll need to contribute through those communities but this set allows node to be built on AIX and pass most of the core tests The change in js2c is because AIX does not support $ in identifier names. See the discussion/agreement in nodejs#2272 PR-URL: nodejs#2364 Reviewed-By: Ben Noordhuis <[email protected]> Reviewed-By: Rod Vagg <[email protected]>
ca40362
to
5a19293
Compare
These are the core changes that allow AIX to compile. There are still some test failures as there are some patches needed for libuv and npm that we'll need to contribute through those communities but this set allows node to be built on AIX and pass most of the core tests The change in js2c is because AIX does not support $ in identifier names. See the discussion/agreement in #2272 PR-URL: #2364 Reviewed-By: Ben Noordhuis <[email protected]> Reviewed-By: Rod Vagg <[email protected]>
This is landable on 4.x, right? |
Landed as 2a17c7f |
These are the core changes that allow AIX to compile. There are still some test failures as there are some patches needed for libuv and npm that we'll need to contribute through those communities but this set allows node to be built on AIX and pass most of the core tests The change in js2c is because AIX does not support $ in identifier names. See the discussion/agreement in #2272 PR-URL: #2364 Reviewed-By: Ben Noordhuis <[email protected]> Reviewed-By: Rod Vagg <[email protected]>
I want this to be landed on 4.X, should I put together a PR ? |
Landed in 4.x now so closing |
These are the core changes that allow AIX to compile. There
are still some test failures as there are some patches needed for
libuv and npm that we'll need to contribute through those
communities but this set allows node to be built on AIX and
pass most of the core tests
The change in tools/js2c.py is because AIX does not support $ in
identifier names. See the discussion/agreement in
#2272